<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>IgH EtherCAT Master: ectty.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtreedata.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectalign" style="padding-left: 0.5em;">
   <div id="projectname">IgH EtherCAT Master
   &#160;<span id="projectnumber">1.5.2</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
  initMenu('',false,false,'search.php','Search');
});
</script>
<div id="main-nav"></div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('ectty_8h_source.html','');});
</script>
<div id="doc-content">
<div class="header">
  <div class="headertitle">
<div class="title">ectty.h</div>  </div>
</div><!--header-->
<div class="contents">
<a href="ectty_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/******************************************************************************</span></div><div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> *  $Id: ectty.h,v bc2d4bf9cbe5 2012/09/06 18:22:24 fp $</span></div><div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> *  Copyright (C) 2006-2008  Florian Pose, Ingenieurgemeinschaft IgH</span></div><div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="comment"> *  This file is part of the IgH EtherCAT master userspace library.</span></div><div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="comment"> *  The IgH EtherCAT master userspace library is free software; you can</span></div><div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="comment"> *  redistribute it and/or modify it under the terms of the GNU Lesser General</span></div><div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="comment"> *  Public License as published by the Free Software Foundation; version 2.1</span></div><div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="comment"> *  of the License.</span></div><div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="comment"> *  The IgH EtherCAT master userspace library is distributed in the hope that</span></div><div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;<span class="comment"> *  it will be useful, but WITHOUT ANY WARRANTY; without even the implied</span></div><div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;<span class="comment"> *  warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the</span></div><div class="line"><a name="l00017"></a><span class="lineno">   17</span>&#160;<span class="comment"> *  GNU Lesser General Public License for more details.</span></div><div class="line"><a name="l00018"></a><span class="lineno">   18</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00019"></a><span class="lineno">   19</span>&#160;<span class="comment"> *  You should have received a copy of the GNU Lesser General Public License</span></div><div class="line"><a name="l00020"></a><span class="lineno">   20</span>&#160;<span class="comment"> *  along with the IgH EtherCAT master userspace library. If not, see</span></div><div class="line"><a name="l00021"></a><span class="lineno">   21</span>&#160;<span class="comment"> *  &lt;http://www.gnu.org/licenses/&gt;.</span></div><div class="line"><a name="l00022"></a><span class="lineno">   22</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00023"></a><span class="lineno">   23</span>&#160;<span class="comment"> *  ---</span></div><div class="line"><a name="l00024"></a><span class="lineno">   24</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00025"></a><span class="lineno">   25</span>&#160;<span class="comment"> *  The license mentioned above concerns the source code only. Using the</span></div><div class="line"><a name="l00026"></a><span class="lineno">   26</span>&#160;<span class="comment"> *  EtherCAT technology and brand is only permitted in compliance with the</span></div><div class="line"><a name="l00027"></a><span class="lineno">   27</span>&#160;<span class="comment"> *  industrial property and similar rights of Beckhoff Automation GmbH.</span></div><div class="line"><a name="l00028"></a><span class="lineno">   28</span>&#160;<span class="comment"> *</span></div><div class="line"><a name="l00029"></a><span class="lineno">   29</span>&#160;<span class="comment"> *****************************************************************************/</span></div><div class="line"><a name="l00030"></a><span class="lineno">   30</span>&#160;</div><div class="line"><a name="l00040"></a><span class="lineno">   40</span>&#160;<span class="comment">/*****************************************************************************/</span></div><div class="line"><a name="l00041"></a><span class="lineno">   41</span>&#160;</div><div class="line"><a name="l00042"></a><span class="lineno">   42</span>&#160;<span class="preprocessor">#ifndef __ECTTY_H__</span></div><div class="line"><a name="l00043"></a><span class="lineno">   43</span>&#160;<span class="preprocessor">#define __ECTTY_H__</span></div><div class="line"><a name="l00044"></a><span class="lineno">   44</span>&#160;</div><div class="line"><a name="l00045"></a><span class="lineno">   45</span>&#160;<span class="preprocessor">#include &lt;linux/termios.h&gt;</span></div><div class="line"><a name="l00046"></a><span class="lineno">   46</span>&#160;</div><div class="line"><a name="l00047"></a><span class="lineno">   47</span>&#160;<span class="comment">/******************************************************************************</span></div><div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;<span class="comment"> * Data types</span></div><div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;<span class="comment"> *****************************************************************************/</span></div><div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;</div><div class="line"><a name="l00051"></a><span class="lineno">   51</span>&#160;<span class="keyword">struct </span>ec_tty;</div><div class="line"><a name="l00052"></a><span class="lineno"><a class="line" href="group__TTYInterface.html#gabf4bbf300a5c451d7fe82b65e17f097d">   52</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>ec_tty <a class="code" href="group__TTYInterface.html#gabf4bbf300a5c451d7fe82b65e17f097d">ec_tty_t</a>; </div><div class="line"><a name="l00056"></a><span class="lineno"><a class="line" href="structec__tty__operations__t.html">   56</a></span>&#160;<span class="keyword">typedef</span> <span class="keyword">struct </span>{</div><div class="line"><a name="l00057"></a><span class="lineno"><a class="line" href="structec__tty__operations__t.html#ae34fae0b4916fbc5d016c7c0fad95a47">   57</a></span>&#160;    int (*cflag_changed)(<span class="keywordtype">void</span> *, tcflag_t); </div><div class="line"><a name="l00061"></a><span class="lineno">   61</span>&#160;} <a class="code" href="structec__tty__operations__t.html">ec_tty_operations_t</a>;</div><div class="line"><a name="l00062"></a><span class="lineno">   62</span>&#160;</div><div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;<span class="comment">/******************************************************************************</span></div><div class="line"><a name="l00064"></a><span class="lineno">   64</span>&#160;<span class="comment"> * Global functions</span></div><div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;<span class="comment"> *****************************************************************************/</span></div><div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;</div><div class="line"><a name="l00074"></a><span class="lineno">   74</span>&#160;<a class="code" href="group__TTYInterface.html#gabf4bbf300a5c451d7fe82b65e17f097d">ec_tty_t</a> *<a class="code" href="group__TTYInterface.html#ga64244c8ea384d633c3f8edfadeecffb3">ectty_create</a>(</div><div class="line"><a name="l00075"></a><span class="lineno">   75</span>&#160;        <span class="keyword">const</span> <a class="code" href="structec__tty__operations__t.html">ec_tty_operations_t</a> *ops,</div><div class="line"><a name="l00076"></a><span class="lineno">   76</span>&#160;        <span class="keywordtype">void</span> *cb_data</div><div class="line"><a name="l00077"></a><span class="lineno">   77</span>&#160;        );</div><div class="line"><a name="l00078"></a><span class="lineno">   78</span>&#160;</div><div class="line"><a name="l00079"></a><span class="lineno">   79</span>&#160;<span class="comment">/******************************************************************************</span></div><div class="line"><a name="l00080"></a><span class="lineno">   80</span>&#160;<span class="comment"> * TTY interface methods</span></div><div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;<span class="comment"> *****************************************************************************/</span></div><div class="line"><a name="l00082"></a><span class="lineno">   82</span>&#160;</div><div class="line"><a name="l00085"></a><span class="lineno">   85</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__TTYInterface.html#ga03d764370f5d76bec71412ea1124a156">ectty_free</a>(</div><div class="line"><a name="l00086"></a><span class="lineno">   86</span>&#160;        <a class="code" href="group__TTYInterface.html#gabf4bbf300a5c451d7fe82b65e17f097d">ec_tty_t</a> *tty </div><div class="line"><a name="l00087"></a><span class="lineno">   87</span>&#160;        );</div><div class="line"><a name="l00088"></a><span class="lineno">   88</span>&#160;</div><div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;<span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> <a class="code" href="group__TTYInterface.html#ga71580e6fbab0aa678073c139bf516dae">ectty_tx_data</a>(</div><div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160;        <a class="code" href="group__TTYInterface.html#gabf4bbf300a5c451d7fe82b65e17f097d">ec_tty_t</a> *tty, </div><div class="line"><a name="l00098"></a><span class="lineno">   98</span>&#160;        uint8_t *buffer, </div><div class="line"><a name="l00099"></a><span class="lineno">   99</span>&#160;        <span class="keywordtype">size_t</span> size </div><div class="line"><a name="l00100"></a><span class="lineno">  100</span>&#160;        );</div><div class="line"><a name="l00101"></a><span class="lineno">  101</span>&#160;</div><div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;<span class="keywordtype">void</span> <a class="code" href="group__TTYInterface.html#ga9d2e53ca7492e1a71a26cbbc7d51af52">ectty_rx_data</a>(</div><div class="line"><a name="l00105"></a><span class="lineno">  105</span>&#160;        <a class="code" href="group__TTYInterface.html#gabf4bbf300a5c451d7fe82b65e17f097d">ec_tty_t</a> *tty, </div><div class="line"><a name="l00106"></a><span class="lineno">  106</span>&#160;        <span class="keyword">const</span> uint8_t *buffer, </div><div class="line"><a name="l00107"></a><span class="lineno">  107</span>&#160;        <span class="keywordtype">size_t</span> size </div><div class="line"><a name="l00108"></a><span class="lineno">  108</span>&#160;        );</div><div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160;</div><div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;<span class="comment">/*****************************************************************************/</span></div><div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160;</div><div class="line"><a name="l00114"></a><span class="lineno">  114</span>&#160;<span class="preprocessor">#endif</span></div><div class="ttc" id="group__TTYInterface_html_gabf4bbf300a5c451d7fe82b65e17f097d"><div class="ttname"><a href="group__TTYInterface.html#gabf4bbf300a5c451d7fe82b65e17f097d">ec_tty_t</a></div><div class="ttdeci">struct ec_tty ec_tty_t</div><div class="ttdef"><b>Definition:</b> <a href="ectty_8h_source.html#l00052">ectty.h:52</a></div></div>
<div class="ttc" id="structec__tty__operations__t_html"><div class="ttname"><a href="structec__tty__operations__t.html">ec_tty_operations_t</a></div><div class="ttdoc">Operations on the virtual TTY interface. </div><div class="ttdef"><b>Definition:</b> <a href="ectty_8h_source.html#l00056">ectty.h:56</a></div></div>
<div class="ttc" id="group__TTYInterface_html_ga64244c8ea384d633c3f8edfadeecffb3"><div class="ttname"><a href="group__TTYInterface.html#ga64244c8ea384d633c3f8edfadeecffb3">ectty_create</a></div><div class="ttdeci">ec_tty_t * ectty_create(const ec_tty_operations_t *ops, void *cb_data)</div><div class="ttdoc">Create a virtual TTY interface. </div></div>
<div class="ttc" id="group__TTYInterface_html_ga03d764370f5d76bec71412ea1124a156"><div class="ttname"><a href="group__TTYInterface.html#ga03d764370f5d76bec71412ea1124a156">ectty_free</a></div><div class="ttdeci">void ectty_free(ec_tty_t *tty)</div><div class="ttdoc">Releases a virtual TTY interface. </div></div>
<div class="ttc" id="group__TTYInterface_html_ga71580e6fbab0aa678073c139bf516dae"><div class="ttname"><a href="group__TTYInterface.html#ga71580e6fbab0aa678073c139bf516dae">ectty_tx_data</a></div><div class="ttdeci">unsigned int ectty_tx_data(ec_tty_t *tty, uint8_t *buffer, size_t size)</div><div class="ttdoc">Reads data to send from the TTY interface. </div></div>
<div class="ttc" id="group__TTYInterface_html_ga9d2e53ca7492e1a71a26cbbc7d51af52"><div class="ttname"><a href="group__TTYInterface.html#ga9d2e53ca7492e1a71a26cbbc7d51af52">ectty_rx_data</a></div><div class="ttdeci">void ectty_rx_data(ec_tty_t *tty, const uint8_t *buffer, size_t size)</div><div class="ttdoc">Pushes received data to the TTY interface. </div></div>
</div><!-- fragment --></div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_d44c64559bbebec7f509842c48db8b23.html">include</a></li><li class="navelem"><a class="el" href="ectty_8h.html">ectty.h</a></li>
    <li class="footer">Generated by
    <a href="http://www.doxygen.org/index.html">
    <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.13 </li>
  </ul>
</div>
</body>
</html>
